package com.thor.palmmall.rest.sales.input;

import java.util.List;

import javax.ws.rs.Consumes;
import javax.ws.rs.GET;
import javax.ws.rs.POST;
import javax.ws.rs.Path;
import javax.ws.rs.PathParam;
import javax.ws.rs.Produces;
import javax.ws.rs.QueryParam;
import javax.ws.rs.core.MediaType;

import com.thor.commons.entity.BeanOperateInfo;
import com.thor.commons.exception.ThorServiceException;
import com.thor.commons.query.QueryResult;
import com.thor.palmmall.rest.common.AUserGroupLoadParam;

/**
 * 销售录入服务接口
 * 
 * @author thor
 * 
 */
@Path("/salesinput")
@Produces(MediaType.APPLICATION_JSON + "; charset=utf-8")
@Consumes(MediaType.APPLICATION_JSON + "; charset=utf-8")
public interface ASalesInputService {

  @POST
  @Path("/create")
  String create(ASalesInput salesInput, @QueryParam("") BeanOperateInfo operateInfo)
      throws ThorServiceException;

  @POST
  @Path(value = "/save")
  String save(ASalesInput salesInput, @QueryParam("") BeanOperateInfo operateInfo)
      throws ThorServiceException;

  @POST
  @Path(value = "/{id}")
  ASalesInput get(@PathParam("id") String id, AUserGroupLoadParam param)
      throws ThorServiceException;

  @POST
  @Path(value = "/query")
  QueryResult<ASalesInput> query(ASalesInputQueryParam param) throws ThorServiceException;

  @POST
  @Path("/getSalesTotal")
  List<ASalesTotalData> getSalesTotal(ASalesInputCondition condition) throws ThorServiceException;

  @GET
  @Path(value = "/getAllPayments")
  List<APayments> getAllPayments() throws ThorServiceException;

  @POST
  @Path(value = "/products")
  List<AContractProducts> products(AProductsParam param) throws ThorServiceException;
}
